package com.youlai.boot.system.model.form;

import java.io.Serial;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import java.time.LocalDateTime;
import com.fasterxml.jackson.annotation.JsonFormat;
import jakarta.validation.constraints.*;

/**
 * 物料表单对象
 *
 * @author lwb
 * @since 2025-07-16 21:52
 */
@Getter
@Setter
@Schema(description = "物料表单对象")
public class LpsWlForm implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "主键")
    private Long id;

    @Schema(description = "物料编码")
    @NotBlank(message = "物料编码不能为空")
    @Size(max=100, message="物料编码长度不能超过100个字符")
    private String no;

    @Schema(description = "物料名称")
    @NotBlank(message = "物料名称不能为空")
    @Size(max=100, message="物料名称长度不能超过100个字符")
    private String name;

    @Schema(description = "父节点id")
    private Long parentId;

    @Schema(description = "显示顺序")
    private Integer sort;

    @Schema(description = "状态(1-是 0-否)")
    private Integer status;

    @Schema(description = "备注")
    @Size(max=65535, message="备注长度不能超过65535个字符")
    private String remark;

    @Schema(description = "创建人ID")
    private Long createBy;

    @Schema(description = "创建时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    @Schema(description = "修改人ID")
    private Long updateBy;

    @Schema(description = "更新时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    @Schema(description = "逻辑删除标识(1-已删除 0-未删除)")
    private Integer isDeleted;


}
